package com.xy.annotaion.handler;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.amqp.RabbitAutoConfiguration;
import org.springframework.boot.autoconfigure.data.redis.RedisAutoConfiguration;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;

/**
 * @author Dell
 */
@SpringBootApplication(exclude = {
		DataSourceAutoConfiguration.class,
		RabbitAutoConfiguration.class,
		RedisAutoConfiguration.class
})
//@EnableJpaRepositories
public class AnnotationHandlerApplication extends SpringBootServletInitializer/*这个继承只有部署到tomcat中才会起作用*/ {


	@Override
	protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
		builder.sources(AnnotationHandlerApplication.class);
		return super.configure(builder);
	}

	public static void main(String[] args) {
		SpringApplication.run(AnnotationHandlerApplication.class, args);
	}

}
